package com.gsww.vue.service.sys.impl;

import java.util.ArrayList;
import java.util.List;
import java.util.Map;

import org.apache.commons.lang3.StringUtils;
import org.springframework.stereotype.Service;
import org.springframework.transaction.annotation.Transactional;

import com.gsww.vue.service.BasicService;
import com.gsww.vue.service.sys.SysParameterTypeService;
@Service
@Transactional
public class SysParameterTypeServiceImpl extends BasicService implements SysParameterTypeService{

	@Override
	public Map<String, Object> getParaTypeList(String paraTypeName, String pageNo, String pageSize) throws Exception {
		List<Object> paramList = new ArrayList<Object>();
		StringBuilder sb = new StringBuilder();
		sb.append("select t.* from sys_parameter_type t where 1=1 ");
		if(StringUtils.isNotBlank(paraTypeName)){
			sb.append(" and t.para_type_name like ?");
			paramList.add("%"+paraTypeName+"%");
		}
		Map<String, Object> map = super.page( sb.toString(),paramList, pageNo, pageSize);
		return map;
	}

}
